next up previous contents index
Next: Character types Up: Data types Previous: Integer types

Real types

Free Pascal uses the math coprocessor (or an emulation) for al its floating-point calculations. The native type for the coprocessor is Double. Other than that, all Turbo Pascal real types are supported. They're listed in table (1.2).

  

Type Range Significant digits Sizegif
Real 2.9E-39 .. 1.7E38 11-12 6
Single 1.5E-45 .. 3.4E38 7-8 4
Double 5.0E-324 .. 1.7E308 15-16 8
Extended 1.9E-4951 .. 1.1E4932 19-20 10
Table 1.2: Supported Real types

Until version 0.9.1 of the compiler, all the real types are mapped to type Double, meaning that they all have size 8. From version 0.9.3, the Extended and single types are defined with the same suze as in Turbo Pascal. The SizeOf function is your friend here.



Michael Van Canneyt
Tue Mar 31 16:48:49 CEST 1998